<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>专业大全</title>
    <script type="text/javascript"  src="http://code.jquery.com/jquery-1.8.3.js"></script>
  <link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" />
  <script type="text/javascript"  src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>
  <link rel="stylesheet" href="index.css">
  <link rel="stylesheet" href="main.css">
  <link rel="stylesheet" href="major.css">
  <link rel="stylesheet" href="./static/dist/css/bootstrap.css">
  <script type="text/javascript" src="./static/store.legacy.min.js"></script>
  <script src="./static/util.js"></script>
</head>
<body>
  <!-- 自主招生页面 -->
  <header>
    <div class="headerSwipper">
      <div class="headerSwipper_div">
        <div class="headerSwipper_div_iconview">
          <img src="./static/images/logo.png" alt="">
        </div>
        <div class="headerSwipper_div_myicon">
          <!-- <img src="" alt=""> -->
          <span class="loginText">登录</span>
          <div class="headerSwipper_div_myicon_icon" style="display: none">
            <img src="./static/images/iconsmall.png" alt="">
          </div>
          <div class="headerSwipper_div_myicon_info">
            <ul>
              <li class="headerSwipper_div_myicon_info_li">消息</li>
              <li class="headerSwipper_div_myicon_info_li">退出</li>
            </ul>
          </div>
        </div>
        <ul class="headerSwipper_div_ul">
          <li class="headerSwipper_div_li mobileapp">手机APP</li>
          <li class="headerSwipper_div_li vipprop">开通VIP</li>
        </ul>
      </div>
    </div>
  </header>
  <section>
    <div class="ImgSwipperview middleheight">
      <img class="ImgSwipperview_img" src="./static/images/magioback.png" alt="">
      <div class="major_div">
        <p class="major_div_title">
          <span class="b_title">哲学</span>
          <span class="s_title">(本科)</span>
        </p>
        <p class="major_div_vicetitle">
          <span class="code">专业代码:<span class="code_server"></span></span>
          <span class="code">所属学科:<span class="sub_server"></span></span>
          <span class="code">所属分类:<span class="type_server"></span></span>
        </p>
        <div class="collect_view">
          <span class="collect_view_span">
            <img class="collect_view_span_img" src="./static/images/collect_not.png" alt="">
          </span>
        </div>
      </div>
    </div>
  </section>
  <section>
    <div class="mainContentView">
      <div class="contentView">
        <!-- 上侧导航 -->
        <div class="topnav">
          <ul class="contentView_ul">
            <li class="contentView_li contentView_li_active">首页</li>
            <li class="contentView_li">学习中心</li>
            <li class="contentView_li">志愿填报</li>
            <li class="contentView_li">微课</li>
            <li class="contentView_li">模拟试题</li>
            <li class="contentView_li">往届真题</li>
            <li class="contentView_li">咨询</li>
          </ul>
          <div class="inputview">
            <input class="inputview_input" id="tag" 
 type="text" placeholder="搜索院校">
            <img  class="searchicon_img" src="./static/images/searchicon.png" alt="">
          </div>
        </div>
      </div>
    </div>
  </section>
  <!-- 学习中心 -->
  <section class="learnCenterPage">
    <div class="learncenterview">
      <div class="learncenter">
        <!-- 专业分类列表 -->
        <div class="major_typeview">
          <ul class="educationBackground ">
            学历:
            <li class="educationBackground_li educationBackground_li_active" li-id="1">本科</li>
            <li class="educationBackground_li" li-id="2">专科</li>
          </ul>
          <ul class="educationBackground type_subject">
            分类:
          </ul>
          <ul class="educationBackground kind_subject">
            门科:
          </ul>
          <ul class="educationBackground sub_subject">
            学科:
          </ul>
        </div>
        <!-- 自主招生页面 -->
        <div class="questionView recruitment_more">
          <!-- <ul class="subjectNav">
            <li class="subjectNav_li">语文</li>
          </ul> -->
          <p class="segmentation moreSmallClass">
            <span class="segmentation_title"></span>
          </p>
          <ul class="questionView_ul recruitment_ul_more">

          </ul>
          <div class="tableview_major">
            <p class="title_year">
                <span>在<span>河南</span>录取情况</span>
                <select name="year_se" id="year_se">
                  <option value="2017">2017</option>
                  <option value="2018">2018</option>
                  <option value="2019">2019</option>
                  <option value="2020">2020</option>
                </select>
              </p>
            <table class="table table-bordered typeziyuan">
              <tr>
                <td>开设院校</td>
                <td>科类</td>
                <td>招生批次</td>
                <td>平均分</td>
              </tr>
            </table>

          </div>

        </div>
        <!-- 分页 来自index.html -->
        <p class="pagingView">
          <span class="pagebtn firstpage">首页</span>
          <span class="pagebtn frontpage">前一页</span>
          <span class="pagesview">
            <!-- 动态添加页码 -->
          </span>
          <span class="pagebtn backpage">后一页</span>
          <span class="pagebtn lastpage">尾页</span>
        </p>
      </div>
    </div>
  </section>

  <footer>
    <div class="footerSwipper">
      <div class="footerSwipper_div">
        <ul class="footerSwipper_div_ul">
          <span class="footerSwipper_div_ul_span"><a href="./index.html">首页</a></span>
          <li class="footerSwipper_div_ul_li"><a href="./schools.html?keyword=">院校大全</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./major.html">专业大全</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./mentality.html">心理辅导</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./careerPlanning.html">职业规划</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./infoTest.html">高考资讯</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./recruitment.html?type=1">自主招生</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./recruitment.html?type=2">单独招生</a></li>
        </ul>
        <ul class="footerSwipper_div_ul">
          <span class="footerSwipper_div_ul_span">学习提升</span>
          <li class="footerSwipper_div_ul_li"><a href="./index.html?index=3">微课</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./index.html?index=4">模拟试题</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./index.html?index=5">往届试题</a></li>
        </ul>
        <ul class="footerSwipper_div_ul">
          <span class="footerSwipper_div_ul_span">志愿填报</span>
          <li class="footerSwipper_div_ul_li"><a href="./index.html?index=6">咨询</a></li>
          <li class="footerSwipper_div_ul_li"><a href="./mobileapp.html">下载APP</a></li>
        </ul>
        <!-- 扫一扫关注我们区域 -->
        <div class="QRcodeSwipper">
          <span class="QRcodeSwipper_span">扫一扫关注我们</span>
          <div class="QRcodeSwipper_imgview">
            <img src="./static/images/qr.png" alt="">
          </div>
        </div>
        <!-- 中间信息区域 -->
        <div class="middleInfo">
          <span class="middleInfo_span_city">中国·河南·郑州</span>
          <span class="middleInfo_span_GE"><span class="middleInfo_span_GE_icon middleInfo_span_GE_icon_special phone_icon"><img src="./static/images/phone.png" alt=""></span><span class="middleInfo_span_GE_text middleInfo_span_GE_text_color">0371-68064945</span></span>
          <span class="middleInfo_span_GE"><span class="middleInfo_span_GE_icon message_icon"><img src="./static/images/message.png" alt=""></span><span class="middleInfo_span_GE_text">595879735@qq.com</span></span>
          <span class="middleInfo_span_GE"><span class="middleInfo_span_GE_icon message_icon"><img src="./static/images/store.png" alt=""></span><span class="middleInfo_span_GE_text">河南柒佰伴教育信息咨询有限公司
          </span></span>
          <span class="middleInfo_span_GE"><span class="middleInfo_span_GE_icon middleInfo_span_GE_icon_special address_icon"><img src="./static/images/address.png" alt=""></span><span class="middleInfo_span_GE_text middleInfo_span_GE_text_special">郑州市郑东新区立体世界
            </span></span>
        </div>
        <p class="footerSwipper_div_p">河南世霖网络软件科技 2014-2018 豫ICP备14010456号-1</p>
      </div>
    </div>
  </footer>
  <script src="./static/util.js"></script>
  <script>
    $(document).ready(function(){
      // 初始化参数
      var currentpage = 1
      var pagestotal = 1
      var testQuestion = {type_nav: 1, type: 1, page: 1}
      var possibleUrl = '/admin.php/api/homepage/zzzs_list'
      var indexlist = [8, 1, 3]
      var index = 0
      var toptype = ['专业介绍','开设院校','就业情况']
      // .learncenter 导入导航标签方法
      // ArrowNavigation($('.learncenter'),["main","smallClass"])
      // 登录隐藏
      $('.headerSwipper_div_myicon_info').hide()
      // 记录li标签是否被点过 避免重复进行ajax 在点击一次加1 0> 10< 绕过ajax请求
      var liajaxUse = [0,0,0,0,0,0,0]
      // 渲染icon区域的图标
      console.log($('.iconItems').find('.iconitem'))
      for(item in $('.iconItems').find('.iconitem')) {
        $('.iconItems').find('.iconitem').eq(item).find('img').attr('src','./static/images/icon0' + (Number(item)+1) + '.png')
      }
      // 监听li选择事件
      $('.contentView_ul').on('click', '.contentView_li', function() {
        
      })

      function fucPage (possibleUrl, testQuestion) {
        $.ajax({
            url: urlhost + possibleUrl,
            type: 'POST',
            data: testQuestion,
            header: {},
            success: function (res) {
              if (res.code == 0) {
                loadingHide()
                var initdata = res
                pagestotal = initdata.last_page
                rendering ($('.recruitment_ul_more'), indexlist[index], initdata.data)
              } else {
                // 移除加载中样式
                loadingHide()
                return(res.data)
              }
            },
            fail: function () {
              alert('网络有问题')
            }
          })
      }
      // 页码方法
      function pagefuc (pagestotal, currentpage){
        // 页面初始化方法
        function init(pagestotal, currentpage) {
          if(pagestotal <= 5) {
            var html = ''
            $('.pagesview').html('')
            for(var i=1; i <= pagestotal; i++) {
              if(i == currentpage) {
                html += '<span class="pageitem pageactive" id="' + i + '">' + i + '</span>'
              }else {
                html += '<span class="pageitem" id="' + i + '">' + i + '</span>'
              }
            }
            $('.pagesview').html(html)
          }else {
            var html = ''
            $('.pagesview').html('')
            var length = (Math.floor(currentpage/5)+1)*5 >= pagestotal?pagestotal:Math.floor(currentpage/5)*5+5
            for(var i=(Math.floor((currentpage-1)/5)+1)*5-4; i <= (Math.floor((currentpage-1)/5)+1)*5; i++) {
              if(i == currentpage) {
                html += '<span class="pageitem pageactive" id="' + i + '">' + i + '</span>'
              }else {
                html += '<span class="pageitem" id="' + i + '">' + i + '</span>'
              }
            }
            $('.pagesview').html(html)
          }
        }
        init(pagestotal, currentpage)
        }
        // 点击页码事件 页码变色 进行获取数据
        $('.pagingView').on('click', '.pageitem', function() {
          if($(this).hasClass('pageactive')) {
            return
          }
          $(this).parent().find('.pageitem').removeClass('pageactive')
          $(this).addClass('pageactive')
          currentpage = $(this).text()
          testQuestion.page = currentpage
          var initdata = ''
          $.ajax({
            url: urlhost + possibleUrl,
            type: 'POST',
            data: testQuestion,
            header: {},
            success: function (res) {
              if (res.code == 0) {
                loadingHide()
                initdata = res
                rendering ($('.recruitment_ul_more'), indexlist[index], initdata.data)

              } else {
                // 移除加载中样式
                loadingHide()
                return(res.data)
              }
            },
            fail: function () {
              alert('网络有问题')
            }
          })
        })
        // 前一页事件
        $('.frontpage').click(
          function() {
            if(currentpage === 1) {
              return
            }
            if($('.pageactive').index() === 0) {
              $('#'+(currentpage+4)).remove()
              currentpage--
              $(this).parent().find('.pageitem').removeClass('pageactive')
              $('.pagesview').prepend('<span class="pageitem pageactive" id="' + currentpage + '">' + currentpage + '</span>')
              testQuestion.page = currentpage
              fucPage(possibleUrl, testQuestion)
              return
            }
            currentpage--
            $(this).parent().find('.pageitem').removeClass('pageactive')
            $('#'+currentpage).addClass('pageactive')
            testQuestion.page = currentpage
            fucPage(possibleUrl, testQuestion)
          }
        )
        // 后一页事件
        $('.backpage').click(
           function() {
            console.log(currentpage)
              if(currentpage === pagestotal) {
                return
              }
              if($('.pageactive').index() === 4) {
                $('#'+(currentpage-4)).remove()
                currentpage++
                $(this).parent().find('.pageitem').removeClass('pageactive')
                $('.pagesview').append('<span class="pageitem pageactive" id="' + currentpage + '">' + currentpage + '</span>')
                testQuestion.page = currentpage
                fucPage(possibleUrl, testQuestion)
                return
              }
              currentpage++
              $(this).parent().find('.pageitem').removeClass('pageactive')
              $('#'+currentpage).addClass('pageactive')
              testQuestion.page = currentpage
              fucPage(possibleUrl, testQuestion)
            }
          )
          // 首页事件
          $('.firstpage').click(
             function() {
              currentpage = 1
              testQuestion.page = currentpage
              fucPage(possibleUrl, testQuestion)
              pagefuc(pagestotal, currentpage)
            }
          )
          // 末尾页点击事件
          $('.lastpage').click(
             function() {
              currentpage = pagestotal
              testQuestion.page = currentpage
              fucPage(possibleUrl, testQuestion)
              pagefuc(pagestotal, currentpage)
            }
          )

      // 渲染子页面数据
      // 微课 topThree
      // <div class="classitem">
      //       <video src="" class="classitem_vidio"></video>
      //       <p class="classitem_p">语文高考知识点分析</p>
      //     </div>
      // 模拟试题 questionView_ul_more
      // <li class="testQuestion">
      //           <span class="leftimgview"><img class="leftimgview_img" src="./static/images/greentest.png" alt=""><span class="leftimgview_text">模拟</span></span>
      //           <div class="infotextview">
      //             <span class="infotextview_title">河南省郑州市高二语文期中试题</span>
      //             <span class="infotextview_time">2018-9-12 </span>
      //             </div>
      //         </li>
      function rendering (item, type, data) {
        var applyhtml = ''
        
         // data获取的数据
        if(type == 5) {
          item.html('')
          applyhtml = data
          item.html(applyhtml)
          return
        }
        var typelist001 = ['','理科','文科']
        var typelist002 = ['','本科一批','本科二批','高职高专']
        if(type == 10) {
          item.find('th').parent().remove()
          console.log(data)
          for(var i=0;i<data.length;i++) {
            applyhtml += '<tr>'
               + '<th>'+ data[i].sch_name +'</th>'
               + '<th>'+ typelist001[data[i].zy_major_status] +'</th>'
               + '<th>'+ typelist002[data[i].zy_obj_status] +'</th>'
               + '<th>'+ data[i].zy_pj_score +'</th>'
             + '</tr>'
          } 
          console.log(applyhtml)
          item.append(applyhtml)
          return
        }
      }
      // 试题上方科目选择列表 方法
      // <ul class="subjectNav">
      //       <li class="subjectNav_li">语文</li>
      //     </ul>
      function subjectApply (item, subjects) {
        item.find('.subjectNav').remove()
        var subject = ''
        for(var i=0; i < subjects.length; i++) {
          if(i == 0) {
            subject += '<li class="subjectNav_li subjectNav_li_active" id="' + i + '">' + subjects[i] + '</li>'
          }else {
            subject += '<li class="subjectNav_li" id="' + i + '">' + subjects[i] + '</li>'
          }
        }
        subject = '<ul class="subjectNav">' + subject + '</ul>'
        item.prepend(subject)
      }
      // 监听自主招生选择改变事件
      $('.recruitment_more').on('click', '.subjectNav_li', function (){
        clickchange($(this), '.subjectNav_li', 'subjectNav_li_active')
        // ajax获取值 重新redering
        testQuestion.type = Number($(this).index()) + 1
        index = $(this).index()
        sub_type_index = index
        $('.segmentation_title').text(toptype[index])
        if(index == 0 || index == 2) {
          $('.pagingView').hide()
          $('.segmentation').show()
          $('.tableview_major').hide()
          rederZyitem(zyactive ,sub_type_index)
          return
        }
        if(index == 1) {
          $('.tableview_major').show()
          $('.segmentation').hide()
          rederZyitem(zyactive ,sub_type_index)
        }
      })
      // 监听查看详情事件
      $('.learncenterview').on('click', '.newsitemview', function() {
        var itemid = $(this).parents('li').attr('id').slice(14)
        window.location.href = './item.html?id=' + itemid
      })
      // 监听学校列表点击事件
      $('.learncenterview').on('click', '.universityView', function() {
        var itemid = $(this).attr('id').slice(6)
        window.location.href = './shoolitem.html?id=' + itemid
      })
      // 页面首页初始化
      function pageinit () {
        var setindex = 0
        ArrowNavigation($('.learncenter'),["main","major"])
        subjectApply($('.recruitment_more'), toptype)
        listtype(1, 0, 0)
        index = setindex
        $('.subjectNav_li').eq(setindex).click()
      }
      pageinit()
      // li标签点击 需要跳转页面 同时传递第几个 进行初始化
      $('.contentView_li').click(
        function() {
          var index = $(this).index()
          window.location.href = './index.html?index=' + index
        }
      )
      window.addEventListener("hashchange",function(event){
        console.log('hahah')
      });
      var a = 1
      var b = 0
      var c = 0
      var sub_type_index = 0
      // 分类区域选择事件
      $('.learncenterview').on('click', '.educationBackground_li', function () {
        var index = $(this).parents('ul').index()
        var id = $(this).index()
        var li_id = $(this).attr('li-id')
        if(index == 0) {
          a =id+1
          listtype(a, 0, 0)
        }else if (index == 1) {
          b = id
          last_two(li_id,a)
        }else if (index == 2) {
          c = id
          last_one(vice_sub_lists, c)
        }else if (index == 3) {
          zyactive = li_id
          rederZyitem(zyactive ,sub_type_index)
        }
        
        clickchange($(this),'.educationBackground_li','educationBackground_li_active')
      })
      // 页面初始化 专业分类方法
      var zyactive
      function listtype (xuli, fenlei, menke) {
        $.ajax({
          url: urlhost + '/admin.php/api/homepage/cate_list',
          method: 'POST',
          data: {
            type: xuli
          },
          success: function (res) {
            var first_list = res.data
            var vice_html = '分类'
            for(var i=0; i < first_list.length; i++) {
              if(i == fenlei) {
                vice_html += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ first_list[i].pids +'">'+ first_list[i].pname +'</li>'
              }else {
                vice_html += '<li class="educationBackground_li" li-id="'+ first_list[i].pids +'">'+ first_list[i].pname +'</li>'
              }
            }
            $('.type_subject').html(vice_html)
            $.ajax({
              url: urlhost + '/admin.php/api/homepage/zy_list',
              method: 'POST',
              data: {
                pid: fenlei || first_list[0].pids,
                type: xuli
              },
              success: function (res2) {
                var second_list = res2.data
                var men_type = '门科'
                var xue_type = '学科'
                for(var j=0; j<second_list.length; j++) {
                  if(j == 0) {
                    men_type += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ second_list[j].cids +'">'+ second_list[j].cname +'</li>'
                  }else {
                    men_type += '<li class="educationBackground_li" li-id="'+ second_list[j].cids +'">'+ second_list[j].cname +'</li>'
                  }
                }
                for(var z=0; z < second_list[menke].list.length; z++) {
                    if(z == 0) {
                      xue_type += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ second_list[menke].list[z].id +'">'+ second_list[menke].list[z].title +'</li>'
                    }else {
                      xue_type += '<li class="educationBackground_li" li-id="'+ second_list[menke].list[z].id +'">'+ second_list[menke].list[z].title +'</li>'
                    }
                  }
                $('.kind_subject').html(men_type)
                $('.sub_subject').html(xue_type)
                zyactive = second_list[0].list[0].id
                rederZyitem(zyactive ,sub_type_index)
              }
            })
          }
        })
      }
      // 渲染专业详情方法
      function rederZyitem(zy_id, url_index) {
        var url_list = ['/admin.php/api/homepage/zy_desc', '/admin.php/api/users/ks_school', '/admin.php/api/homepage/work_status']
        var reder_index = [5,10,5]
        var data = {zid: zy_id}
        if(url_index == 1) {
          data.year = $('#year_se').val()
          // console.log(data)
        }
        $.ajax({
          url: urlhost + url_list[url_index],
          method: 'POST',
          data: data,
          success: function (res) {
            if(res.code == 0) {
              if(url_index == 0) {
                rendering ($('.recruitment_ul_more'), reder_index[url_index], res.data.desc)
              }else if (url_index == 2) {
                rendering ($('.recruitment_ul_more'), reder_index[url_index], res.data.work_status)
              }else {
                $('.questionView_ul').empty()
                rendering ($('.typeziyuan'), reder_index[url_index], res.data)
              }
              $.ajax({
                url: urlhost + '/admin.php/api/homepage/zy_detail',
                method: 'POST',
                data: {
                  zid: zy_id,
                  uid: store.get('uid')
                },
                success: function (res) {
                  // 修改标题
                  var list = ['本科','专科']
                  var imglist = ['./static/images/collect_not.png','./static/images/collect.png']
                  $('.b_title').text(res.data.title)
                  $('.code_server').text(res.data.zy_dm)
                  $('.sub_server').text(res.data.pname)
                  $('.type_server').text(res.data.cname)
                  $('.s_title').text('(' + res.data.type + ')')
                  $('.collect_view_span_img').attr('src', imglist[res.data.status])
                }
              })
            }
          }
        })
      }
      // 渲染最后两层
      var vice_sub_lists
      function last_two (active_id, xueli_index) {
        $.ajax({
          url: urlhost + '/admin.php/api/homepage/zy_list',
          method: 'POST',
          data: {
            pid: active_id,
            type: xueli_index
          },
          success: function (res2) {
            var second_list = res2.data
            vice_sub_lists = res2.data
            var men_type = '门科'
            var xue_type = '学科'
            for(var j=0; j<second_list.length; j++) {
              if(j == 0) {
                men_type += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ second_list[j].cids +'">'+ second_list[j].cname +'</li>'
              }else {
                men_type += '<li class="educationBackground_li" li-id="'+ second_list[j].cids +'">'+ second_list[j].cname +'</li>'
              }
            }
            for(var z=0; z < second_list[0].list.length; z++) {
              if(z == 0) {
                xue_type += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ second_list[0].list[z].id +'">'+ second_list[0].list[z].title +'</li>'
              }else {
                xue_type += '<li class="educationBackground_li" li-id="'+ second_list[0].list[z].id +'">'+ second_list[0].list[z].title +'</li>'
              }
            }
            $('.kind_subject').html(men_type)
            $('.sub_subject').html(xue_type)
            zyactive = second_list[0].list[0].id
            rederZyitem(zyactive ,sub_type_index)
          }
        })
      }
      // 渲染最后一层
      function last_one (data, index) {
        var xue_type = '学科'
        for(var z=0; z < data[index].list.length; z++) {
          if(z == 0) {
            xue_type += '<li class="educationBackground_li educationBackground_li_active" li-id="'+ data[index].list[z].id +'">'+ data[index].list[z].title +'</li>'
          }else {
            xue_type += '<li class="educationBackground_li" li-id="'+ data[index].list[z].id +'">'+ data[index].list[z].title +'</li>'
          }
        }
        $('.sub_subject').html(xue_type)
        zyactive = data[index].list[0].id
        rederZyitem(zyactive ,sub_type_index)
      }
       // 点击图片收藏院校
       $('.major_div').on('click', '.collect_view_span_img', function () {
        if($(this).attr('src') == './static/images/collect_not.png') {
          $(this).attr('src', './static/images/collect.png')
          $.ajax({
            url: urlhost + '/admin.php/api/users/zy_sc',
            method: 'POST',
            data: {
              uid: store.get('uid'),
              flag: 1,
              zy_id: zyactive
            },
            success: function (res) {
              widowAle(res.msg)
            }
          })
        }else {
          $(this).attr('src', './static/images/collect_not.png')
          $.ajax({
            url: urlhost + '/admin.php/api/users/zy_sc',
            method: 'POST',
            data: {
              uid: store.get('uid'),
              flag: 2,
              zy_id: zyactive
            },
            success: function (res) {
              widowAle(res.msg)
            }
          })
        }
      })
      // 年份改变事件
      $('.learncenterview').on('change', '#year_se', function () {
        var val = $(this).val()
        rederZyitem(zyactive, 1)
      })
    })
  </script>
  </body>
</html>
